﻿using MainInterface;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Xml;

namespace MainFrameProperty
{
    public class UIMethod:IComponentXml
    {
        public string Name { get; set; }
        public string ChinaName { get; set; }
        public string Description { get; set; }
        public Dictionary<string, string> Args = new Dictionary<string, string>();
        public void LoadXmlZYK(System.Xml.XmlNode Node)
        {
             XmlAttribute attr=Node.Attributes["Name"];
             this.Name = attr.Value;
             attr = Node.Attributes["ChinaName"];
             this.ChinaName = attr.Value;
             attr = Node.Attributes["Description"];
             this.Description = attr.Value;
             foreach (XmlNode item in Node.ChildNodes)
             {
                 string argname = item.Attributes["Name"].Value;
                 string argdescription = item.Attributes["Description"].Value;
                 if (!Args.ContainsKey(argname))
                 {
                     Args.Add(argname, argdescription);
                 }
             }
        }

        public void GetXml(System.Xml.XmlDocument doc, System.Xml.XmlNode Parent)
        {
            throw new NotImplementedException();
        }

        public void LoadUI(System.Xml.XmlNode node)
        {
            throw new NotImplementedException();
        }
    }
}
